<?php foreach ($model as $data) : ?>
<div class="event-item">
	<div class="event-image">
    	<a href="<?php echo Yii::app()->createurl('/Events/default/view', array('category'=>$data->category->url, 'url'=>$data->url)); ?>" title="<?php echo $data->title; ?>">
    		<img src="<?php echo IMAGES_URL . 'events/thumbs/' , date('Ymd', strtotime($data->posteddate)), '/', $data->image; ?>" alt="<?php echo $data->title; ?>" />
        </a>
    </div>
    <div class="event-content">
    	<?php echo CHtml::link($data->title, array('/Events/default/view', 'category'=>$data->category->url, 'url'=>$data->url), array('title'=>$data->title)); ?>
        <p><span class="glyphicon glyphicon-time"></span> <?php echo $data->startdate; ?></p>
    </div>
</div>
<?php endforeach; ?>